import request from '@/utils/request';
import { BASE_URL, BASE_URLV2 } from '@/config/query';

export async function queryFire() {
  return request(`${BASE_URL}/device_alarm/fire/week/chart`);
}

export async function queryIncidence(params) {
  return request(`${BASE_URL}/device_state/device_state_month_top10`, params)
}

//设备状态报警占比
export async function queryAlarmTotal(params) {
  return request(`${BASE_URL}/device_state/group`, params)
}

//报警时段分布
export async function queryAlarmDistribution(params) {
  return request(`${BASE_URL}/device_state/time/group`, params)
}

//报警趋势
export async function queryAlarmTrend(params) {
  return request(`${BASE_URL}/device_state/time/chart`, params)
}

//获取单位消防报告-报警处理率
export async function queryAlarmHandleRate() {
  return request(`${BASE_URL}/device_state/device_state_handle_rate`)
}

//单位消防报告-消防检查情况
export async function queryReportItems() {
  return request(`${BASE_URL}/check_anwser/last_month`)
}
